﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Story
{

    public class DialogStateEnd : DialogStateBase
    {
        public DialogStateEnd(DialogState state, StoryDialogManager controller)
            : base(state, controller)
        {

        }

        public override void Enter()
        {
            dialogManager.Clear();
            dialogManager.PreUnloadResoruce();
            dialogManager.isPreloadResourceComplete = false;
            dialogManager.gameObject.SetActive(false);
            if (dialogManager.endCallbackHandler != null)
            {
                dialogManager.endCallbackHandler();
                dialogManager.endCallbackHandler = null;
            }
        }
    }

}


